<extend name="Layout/ins_page" />
<block name="content">
	{:W('PageHeader/simple',array('name'=>'系统参数'))}
	<div class="layui-tab layui-tab-brief" >
		<ul class="layui-tab-title">
			<li>
				<a  href="{:U('index')}">基本设置</a>
			</li>
			<li>
				<a href="{:U('weixin')}">微信设置</a>
			</li>
			<li>
				<a href="{:U('weixin_menu')}">微信菜单</a>
			</li>
			<li>
				<a  href="{:U('config')}">系统参数</a>
			</li>
			<li class="layui-this">
				<a href="#">推送设置</a>
			</li>
		</ul>
		<div class="sub-frame gray">
			<form id="form_push" name="form_push" method="post" >
				<input type="hidden" name="data_type" value="system_push">
				<div class="layui-sub-form-item ">
					<label class="layui-form-label text-right" for="ws_push_config">网页推送设置：</label>
					<div class="layui-input-block">
						<input class="layui-input" type="text" id="ws_push_config" name="ws_push_config" value="{$push_data.ws_push_config}">
					</div>
				</div>
				<div class="layui-sub-form-item ">
					<label class="layui-form-label text-right" for="weixin_push_config">微信推送设置：</label>
					<div class="layui-input-block">
						<input class="layui-input" type="text" id="weixin_push_config" name="weixin_push_config" value="{$push_data.weixin_push_config}" >
					</div>
				</div>
				<div class="layui-sub-form-item ">
					<label class="layui-form-label text-right" for="msg_push_config">微信分类推送：</label>
					<div class="layui-input-block">
						<input class="layui-input" type="text" id="msg_push_config" name="msg_push_config" value="{$push_data.msg_push_config}">
					</div>
				</div>
				<div class="layui-sub-form-item ">
					<label class="layui-form-label text-right" for="ws_push_config">消息弹窗时间：</label>
					<div class="layui-input-block">
						<input class="layui-input col-6" type="text" id="ws_push_time" name="ws_push_time" value="{$push_data.ws_push_time}">
					</div>
				</div>
				<div class="layui-sub-form-item ">
					<label class="layui-form-label"></label>
					<div class="layui-input-block">
						<a id="btn_save_push" class="btn">保存</a>
					</div>
				</div>
			</form>
		</div>
	</div>
</block>
<block name="js">
	<script type="text/javascript">
		layui.use('global', function() {
			var $ = layui.jquery;

			$("#btn_save_push").on('click', function() {
				send_form("form_push", "{:U('save')}", "{:U('index')}", function(ret) {
					if (ret.status) {
						layer.msg(ret.info, {
							time : 1200
						}, function() {
							location.reload(true);
						});
					} else {
						layer.msg(ret.info);
						return false;
					}
				});
			});
		});

	</script>
</block>